package blackhouse.advanced;

import java.util.Enumeration;
import java.util.Hashtable;

public class HashtableTest
{
	public static void main(String[] args)
	{
        Hashtable numbers= new Hashtable();
        numbers.put(new Mykey("zhangsan",18), new Integer(1));
        numbers.put(new Mykey("lisi",15), new Integer(2));
        numbers.put(new Mykey("wangwu",20), new Integer(3));
        
        Enumeration e  =numbers.keys();
        while(e.hasMoreElements())
        {
        	Mykey key = (Mykey)e.nextElement();
        	System.out.print(key+"=");
        	System.out.println(numbers.get(key));
        }
	}
}
